<?xml version="1.0" encoding="UTF-8" ?>
<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@taglib prefix="s" uri="/struts-tags" %>
<%@ taglib prefix="c"  uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>编辑公司信息</title>
<script type="text/javascript" src="recruit/jquery.js"></script>
<script type="text/javascript">
function cleanDiv(){
	document.getElementById('l1').innerHTML="";
}
$(document).ready(function(){
	
	$("#compn").blur( function () { 
		
		if(document.getElementById('compn').value.length!=0){
				$.ajax({
					   type: "POST",
					   url: "checkCompanyName.action",
					   data: {jsonString: $("#compn").val()},
					   success: function(returnMassage){
					    	    document.getElementById('l1').innerHTML=returnMassage;
					    }
				});			   
		}		  
	});
});
</script>
</head>
<body>
<div id="l1"></div>
	<s:form action="editCompany" method="POST" validate="true">
		<s:textfield id="compn" name="company.companyName" label="公司名称" onfocus="cleanDiv();"></s:textfield>
		<s:textfield name="company.companyURL" label="网址"></s:textfield>
		<s:textfield name="company.companyLinkMan" label="联系人"></s:textfield>
		<s:textfield name="company.companyPhone" label="联系电话"></s:textfield>
		<s:textfield name="company.companyEmail" label="邮箱"></s:textfield>
		<s:textfield name="company.companyAddress" label="地址"></s:textfield>
		<s:textarea name="company.companyDescription" label="公司简介"></s:textarea>
		<s:hidden name="company.id" value="%{company.id}"></s:hidden>
		<s:submit value="提交"></s:submit>
	</s:form>
</body>
</html>